import logging

import allure
from appium.webdriver.common.appiumby import AppiumBy

from base.base_page import BasePage
from pages.gallery_page import GalleryPage
from pages.helper_page import HelperPage
from pages.setting_page import SettingPage


class HomePage(BasePage):

    _bind_devices = (AppiumBy.XPATH, '//android.widget.TextView[@resource-id="com.sharge.glasses.phone:id/tv_bind_device"]')


    @allure.step("点击绑定设备")
    def bind_devices(self):
        self.find_and_click(self._bind_devices)
        self.wait_for_one_second(2)